package com.augmentum.oes.exception;

import java.util.Map;

/**
 * Exception to validate common parameter error.
 */
public class ParameterException extends BaseException {
    private static final long serialVersionUID = 36641437566796273L;
    private Map<String, String> errorFields;

    public ParameterException(String errorMessage) {
        super(errorMessage);
    }

    public ParameterException(int errorCode, Map<String, String> errorFields) {
        super(errorCode);
        setErrorFields(errorFields);
    }

    public ParameterException(int errorCode, String errorMessage, Map<String, String> errorFields) {
        super(errorCode, errorMessage);
        setErrorFields(errorFields);
    }

    public Map<String, String> getErrorFields() {
        return errorFields;
    }

    public void setErrorFields(Map<String, String> errorFields) {
        this.errorFields = errorFields;
    }
}
